widgetpaintable: Redo implementation
authorBenjamin Otte <otte@redhat.com>
Thu, 5 Jul 2018 19:42:39 +0000 (21:42 +0200)
committerBenjamin Otte <otte@redhat.com>
Fri, 13 Jul 2018 12:56:04 +0000 (14:56 +0200)
commitbcfd1bbd242823c1f3283df1e4bb534e8504a292
tree2bc00f10de6fe64f73b24abf529fc95eb212f037
parent1a5e60be7c57bd3e9f93cdecd74c5dd80c1c02c7
widgetpaintable: Redo implementation

Instead of instantly invalidating, we now cache the old render node and
do the update in an idle handler.
While that gives us a 1 frame delay, it avoids all the tricky things
like queueing resizes while resizing or queueing draws while drawing.

The only remaining issue (and a *big* one at that) is that a nested
widget paintable will now cause the widget to snapshot its previous
render node when creating a new one. And that one will snapshot its
previous render node, and that one will...
And nothing so far breaks this recursion.
gtk/gtkwidget.c
gtk/gtkwidgetpaintable.c
gtk/gtkwidgetpaintableprivate.h